
import { Module, forwardRef } from '@nestjs/common';
import { UserCreateController } from './controllers/user-create.controller'
import { UserCreateCommandHandler } from './commands/user-create.command.handler'
import { UserCreateEvent } from './events/user-create.event'
import { UserModule } from '@/user/user.module'
// 注入实体的订阅者
const CommandHandlers = [UserCreateCommandHandler]
const eventHandlers = [UserCreateEvent]
@Module({
  imports: [
    forwardRef(() => UserModule),
  ],
  controllers: [UserCreateController],
  providers: [
    ...CommandHandlers,
    ...eventHandlers,
  ],
  exports: []
})
export class UserCreateModule { }


